<!-- !+tabs -->

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <script src="js/react.js"></script>
    <script src="js/browser.min.js"></script>
    <script src="js/react-dom.js"></script>
</head>
<body>
    <div id="example"></div>

    <script type="text/babel">
        var TestButton = React.createClass({
            render:function(){
                return <button>
                {this.props.btnText}
                </button>
            }
        });

        ReactDOM.render(
            <TestButton btnText="添加到购物车">
            </TestButton>,
            document.getElementById('example')
        );
    </script>
</body>
</html>